package com.ywgt.functioninterface;

import java.util.function.Consumer;

public class ConsumerTest {
    public static void main(String[] args) {
        Consumer<String> consumer = new Consumer<String>() {
            @Override
            public void accept(String str) {
                System.out.println(str);
            }
        };
        Consumer cons=(str)->{ System.out.println(str); };
        cons.accept("gg");
    }
}
